//
//  TKIM.h
//  TKIM
//
//  Created by liupm on 15/7/24.
//  Copyright (c) 2015年 liupm. All rights reserved.
//

#define TKIMSDK_BACK_CHAT_ACTION @"TKIMSDK_BACK_CHAT_ACTION" //最顶层返回按钮
//当前的版本序号
#define TKIMAppVersionSn 9
#define TKIMAppVersion                                                         \
  [[NSDictionary alloc]                                                        \
      initWithContentsOfFile:[[NSBundle mainBundle] pathForResource:@"Info"    \
                                                             ofType:@"plist"]] \
      [@"CFBundleShortVersionString"]
#define isNeedVideoChat 0

//屏幕宽
#define TKIMScreenWidth [UIScreen mainScreen].bounds.size.width
//屏幕高
#define TKIMScreenHeight [UIScreen mainScreen].bounds.size.height

// 判断是否是iPhone X
#define iPhoneX ([UIScreen instancesRespondToSelector:@selector(currentMode)] ? CGSizeEqualToSize(CGSizeMake(1125, 2436), [[UIScreen mainScreen] currentMode].size) : NO)

#define isIPhoneXSeries     ([UIScreen instancesRespondToSelector:@selector(currentMode)] ?\
(\
CGSizeEqualToSize(CGSizeMake(375, 812),[UIScreen mainScreen].bounds.size)\
||\
CGSizeEqualToSize(CGSizeMake(414, 896),[UIScreen mainScreen].bounds.size)\
)\
:\
NO)

// 状态栏高度
#define STATUS_BAR_HEIGHT (isIPhoneXSeries ? 44.f : 20.f)
// 导航栏高度
#define NAVIGATION_BAR_HEIGHT (isIPhoneXSeries ? 88.f : 64.f)
// tabBar高度
#define TAB_BAR_HEIGHT (isIPhoneXSeries ? (49.f+34.f) : 49.f)
// home indicator
#define HOME_INDICATOR_HEIGHT (isIPhoneXSeries ? 34.f : 0.f)

#define TKIMBbundlePath                                                        \
  [[NSBundle mainBundle] pathForResource:@"TKIMSDKAssets" ofType:@"bundle"]

// 资源文件路径
#define TKIMSrcName(file)                                                      \
  [[[NSBundle mainBundle] pathForResource:@"TKIMSDKAssets" ofType:@"bundle"]   \
      stringByAppendingPathComponent:file]
#define TKIMSrcName2(file)                                                     \
  [[[NSBundle mainBundle] bundlePath] stringByAppendingPathComponent:file]
//获得bundle中的图片
#define TKIMGetImage(file) [TKIMSourceHelper getImage:file]
#define TKIMGetImage2(file) [TKIMSourceHelper getImage2:file]
//登录成功
#define TKIMLoginSucEvent @"TKIMLoginSucEvent"
//退出登录
#define TKIMLoginOutEvent @"TKIMLoginOutEvent"
//显示视频语音聊天事件
#define TKIMShowVideoVoiceNotification @"TKIMShowVideoVoiceNotification"
//未登录通知
#define TKIMNotLoginNotification @"TKIMNotLoginNotification"

#define TKIMImageSelectedEvent @"TKIMImageSelectedEvent"
#define TKIMSendLocationEvent @"TKIMSendLocationEvent"
#define TKIMLocationClickEvent @"TKIMLocationClickEvent"

//消息被点击事件
#define TKIMMsgClickEvent @"TKIMMsgClickEvent"

#define TKIMSendPhotoEvent @"TKIMSendPhotoEvent"
#define TKIMVideoSelectedEvent @"TKIMVideoSelectedEvent"
#define TKIMVideoChatSelectedEvent @"TKIMVideoChatSelectedEvent"
#define TKIMAudioChatSelectedEvent @"TKIMAudioChatSelectedEvent"
#define TKIMSendQuickReplyEvent @"TKIMSendQuickReplyEvent"
#define TKIMScoreEvent @"TKIMScoreEvent"
#define TKIMLoginAccount                                                       \
  @"TKIMLoginAccount"                              //独立出登录账号，用于账号还没存进缓存之前，即第一次登录（用在判断投顾类型）
#define TKIMMoveGroupEvent @"TKIMMoveGroupEvent"   //移动分组
#define TKIMChangeGroupName @"TKIMChangeGroupName" //修改组名称
#define TKIMModifyNicknameNotification                                         \
  @"TKIMModifyNicknameNotification" //修改好友备注的通知
#define TKIMModifyIconNotification                                             \
  @"TKIMModifyIconNotification" //修改自己头像的通知
#define TKIMModifyDescriptionNotification                                      \
  @"TKIMModifyDescriptionNotification" //修改个性签名
#define kTKIMPacketStatus                                                      \
  [NSString                                                                    \
      stringWithFormat:@"%@TKIMPacketStatus",                                  \
                       [TKIMSDKHelper getLoginUserName]] //存储分组的状态
#define kTKIMPacketListExist                                                   \
  [NSString stringWithFormat:@"%@TKIMPacketListExist",                         \
                             [TKIMSDKHelper                                    \
                                 getLoginUserName]] //本地是否存在好友列表

//@事件
#define TKIMRemindEvent @"TKIMRemindEvent"
#define TKIMModifyNicknameNotification @"TKIMModifyNicknameNotification"

#define TKIMSDK_GO_H5 @"TKIMSDK_GO_H5"
#define MESSAGE_ITEM_CLICK @"MESSAGE_ITEM_CLICK"   //第三方事件处理
#define TKIMSDK_BACK_ACTION @"TKIMSDK_BACK_ACTION" //最顶层返回按钮
#define TKIMSDK_OPEN_NEW_CUSTOMER_SERVICE @"TKIMSDK_OPEN_NEW_CUSTOMER_SERVICE" //打开智能客服
#define TKIMSDK_CS_URL @"TKIMSDK_CS_URL" //取URL的key
#define TKIMSDK_BACK_CHAT_ACTION @"TKIMSDK_BACK_CHAT_ACTION" //最顶层返回按钮
#define TKIMSDK_GUJIAYUJING_MSGCOUNT                                           \
  @"TKIMSDK_GUJIAYUJING_MSGCOUNT" //存储股价预警的未读数

#define kLASTSENDINITMSG_TIME  @"kLASTSENDINITMSG_TIME"  //上次发送时间

#define APP_SDK_KEY @"ebondCust"
//#define APP_SDK_KEY @"efortune"
//#define APP_SDK_KEY  @"msgcenter"
//#define APP_SDK_KEY  @"caifutong"
//#define APP_SDK_KEY  @"ebscn"
//#define APP_SDK_KEY  @"huaan"
//#define APP_SDK_KEY @"ZJBroker"
//#define APP_SDK_KEY  @"foursea"

#import "TKIMChatViewController.h"
#import "TKIMConverseViewController.h"
#import "TKIMHelper.h"
#import "TKIMImagePicker.h"
#import "TKIMImageView.h"
#import "TKIMLabel.h"
#import "TKIMLayerUtils.h"
#import "TKIMMsgExt.h"
#import "TKIMRootViewController.h"
#import "TKIMChatRootViewController.h"
#import "TKIMSourceHelper.h"
//#import "TKIMSwipeBack.h"
#import "TKIMTypeDefinition.h"
#import "TKIMUserExt.h"
#import "UIResponder+Router.h"
#import "UIView+TKIM.h"
#import "YYText.h"

//第三方库头文件
//#import "FMTagsView.h"
//#import "MJRefresh.h"
#import "Masonry.h"
//#import <Masonry.h>
#import <SDWebImage.h>
//#import "TKBaseLanguageTableViewCell.h"
//#import "TKIMHeadView.h"
//#import "TKUserInfoViewController.h"
//#import "UITableView+FDIndexPathHeightCache.h"
//#import "UITableView+FDKeyedHeightCache.h"
//#import "UITableView+FDTemplateLayoutCell.h"

// UIExt快捷导入头文件
//#import "TKDefine.h"

//颜色数组
#define TKIMHeadViewColors                                                     \
  @[ @"#4FBDF2", @"#3BC2B4", @"#77BF6D", @"#BD84CD", @"#F6BF26" ];

#define TKIMSwitchOnTintColor                                                  \
  [UIColor colorWithRed:0.84 green:0.94 blue:1.0 alpha:1]
#define TKIMSwitchTintColor                                                    \
  [UIColor colorWithRed:0.95 green:0.95 blue:0.95 alpha:1]

#define isNeedBack 1           //是否需要返回
#define isCaiFuTong 1          //是否是财付通
#define isCaiFuTongNeedStock 0 //财付通是否需要股价预警



#if __has_include("UIImageView+WebCache.h")
#import "SDWebImageManager.h"
#import "UIImage+GIF.h"
#import "UIImageView+WebCache.h"
#else

#endif

#if __has_include("TKSelectPhotoAssets.h")
#import "TKSelectPhotoAssets.h"
#import "TKSelectPhotoNavigationViewController.h"
#import "TKSelectPhotoPickerBrowserPhoto.h"
#import "TKSelectPhotoPickerBrowserPhotoScrollView.h"
#else
#endif





//#if isCaiFuTong
//#import "SDWebImageManager.h"
//#import "TKSelectPhotoAssets.h"
//#import "TKSelectPhotoNavigationViewController.h"
//#import "TKSelectPhotoPickerBrowserPhoto.h"
//#import "TKSelectPhotoPickerBrowserPhotoScrollView.h"
//#import "UIImage+GIF.h"
//#import "UIImage+GIF2.h"
//#import "UIImageView+WebCache.h"
//#else
//#endif

